import * as React from 'react'
import * as ReactDOM from 'react-dom'
import { HashRouter, Match, Miss, Link } from 'react-router'
import { getGlobalDispatcher, ComponentProps, ComponentState, Component } from 'react-channel'

export class Home extends Component<ComponentProps, ComponentState> {
  constructor(props: ComponentProps) {
    super(props)
    this.on('chgPackageSelector', (e) => 
      getGlobalDispatcher().notify('/rpm/package/list', 'changeSelector', e.target.value))
    this.on('chgLikename', (e) =>
      getGlobalDispatcher().notify('/rpm/package/list', 'changeLinename', e.target.value))
  }

  public render() {
    return (
      <ul>
        <li>
          <Link to="/message">hello title</Link><br /><br />
        </li>
      </ul>
    )
  }
}